/**
 * 日期段处理
 * 用来封装大量关于时间的处理
 */

/**
 * 通过系统当前时间，来获取日期段处理
 */
export const getTime = () => {
  let mess = "";
  let hours = new Date().getHours();

  if (hours < 6) {
    mess = "清晨";
  } else if (hours < 9) {
    mess = "早上";
  } else if (hours <= 12) {
    mess = "上午";
  } else if (hours <= 13) {
    mess = "中午";
  } else if (hours <= 18) {
    mess = "下午";
  } else {
    mess = "晚上";
  }
  return mess;
};
